package com.lmz.cart.service;

import com.lmz.cart.vo.Cart;
import com.lmz.cart.vo.CartItem;

import java.util.List;
import java.util.concurrent.ExecutionException;

public interface cartService {
    //将商品添加到购物车
    CartItem addToCart(Long skuId, Integer num) throws ExecutionException, InterruptedException;

    CartItem getCartItem(Long skuId); //获取购物车中某个购物项

    Cart getCart() throws ExecutionException, InterruptedException; //获取购物车

    void checkItem(Long skuId, Integer check); //勾选

    void countItem(Long skuId, Integer num); //改变商品的数量

    void deleteItem(Long skuId); //删除购物项

    List<CartItem> getUserCartItems();


}